package pack;


import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.batch.item.ItemProcessor;
import pack.bean.ReadData;
import pack.bean.WriteData;

/**
 * @author zzxx_zhangzhiwei
 * @Date 2020/10/13 11:19 上午
 */
public class PersonItemProcessor implements ItemProcessor<ReadData, WriteData> {

    private static final Logger LOGGER =
            LoggerFactory.getLogger(PersonItemProcessor.class);

    @Override
    public WriteData process(ReadData readData) {
        WriteData writeData = new WriteData();
        writeData.setId(readData.getId());
        writeData.setNo(readData.getMobileNo());
        writeData.setName(readData.getName());
        return writeData;
    }
}
